#pragma once

namespace DABG {

	using namespace System;
	using namespace System::ComponentModel;
	using namespace System::Collections;
	using namespace System::Windows::Forms;
	using namespace System::Data;
	using namespace System::Drawing;

	public ref class frmStrategy1 : public System::Windows::Forms::Form
	{
	public:
		frmStrategy1(Account ^acc)
		{
			accPointer = acc;
			InitializeComponent();
		}

	protected:
		~frmStrategy1()
		{
			if (components)
			{
				delete components;
			}
		}
	private: System::Windows::Forms::ComboBox^  cbLimit4Pro;
	protected: 
	private: System::Windows::Forms::ComboBox^  cbLimit3Pro;
	private: System::Windows::Forms::ComboBox^  cbLimit2Pro;
	private: System::Windows::Forms::ComboBox^  cbLimit1Pro;
	private: System::Windows::Forms::Label^  label12;
	private: System::Windows::Forms::Button^  btnApplyL;
	private: System::Windows::Forms::Label^  label14;
	private: System::Windows::Forms::Label^  label13;
	private: System::Windows::Forms::Label^  label11;
	private: System::Windows::Forms::Label^  label6;
	private: System::Windows::Forms::TextBox^  txtLimit3Dst;
	private: System::Windows::Forms::Label^  label7;
	private: System::Windows::Forms::TextBox^  txtLimit4Dst;
	private: System::Windows::Forms::TextBox^  txtLimit1Dst;
	private: System::Windows::Forms::TextBox^  txtLimit2Dst;
	private: System::Windows::Forms::Label^  lblInfo6;


	private: System::Windows::Forms::Label^  lblInfo4;


	private: System::Windows::Forms::Label^  lblInfo2;



	private: System::Windows::Forms::TextBox^  txtTideStop;
	private: System::Windows::Forms::TextBox^  txtTriggerSpread;
	private: System::Windows::Forms::Label^  label8;
	private: System::Windows::Forms::TextBox^  txtRoundPrice;
	private: System::Windows::Forms::Label^  label9;
	private: System::Windows::Forms::Label^  label15;
	private: System::Windows::Forms::ToolTip^  toolTip1;
	private: System::Windows::Forms::Label^  label1;
	private: System::Windows::Forms::TextBox^  txtTideStopSpace;
	private: System::Windows::Forms::Label^  lblInfo3;


	private: System::Windows::Forms::Label^  label2;
	private: System::Windows::Forms::TextBox^  txtRoundStopPrice;
	private: System::Windows::Forms::Label^  lblInfo7;


	private: System::Windows::Forms::Label^  lblInfo1;
	private: System::Windows::Forms::Label^  label3;
	private: System::Windows::Forms::TextBox^  txtStopLossSpread;
	private: System::Windows::Forms::Label^  lblInfo5;
	private: System::Windows::Forms::Label^  label4;
	private: System::Windows::Forms::TextBox^  txtTideStopStartAfter;
	private: System::Windows::Forms::Label^  lblInfo8;






	private: System::ComponentModel::IContainer^  components;

	private:


#pragma region Windows Form Designer generated code
		void InitializeComponent(void)
		{
			this->components = (gcnew System::ComponentModel::Container());
			this->cbLimit4Pro = (gcnew System::Windows::Forms::ComboBox());
			this->cbLimit3Pro = (gcnew System::Windows::Forms::ComboBox());
			this->cbLimit2Pro = (gcnew System::Windows::Forms::ComboBox());
			this->cbLimit1Pro = (gcnew System::Windows::Forms::ComboBox());
			this->label12 = (gcnew System::Windows::Forms::Label());
			this->btnApplyL = (gcnew System::Windows::Forms::Button());
			this->label14 = (gcnew System::Windows::Forms::Label());
			this->label13 = (gcnew System::Windows::Forms::Label());
			this->label11 = (gcnew System::Windows::Forms::Label());
			this->label6 = (gcnew System::Windows::Forms::Label());
			this->txtLimit3Dst = (gcnew System::Windows::Forms::TextBox());
			this->label7 = (gcnew System::Windows::Forms::Label());
			this->txtLimit4Dst = (gcnew System::Windows::Forms::TextBox());
			this->txtLimit1Dst = (gcnew System::Windows::Forms::TextBox());
			this->txtLimit2Dst = (gcnew System::Windows::Forms::TextBox());
			this->lblInfo6 = (gcnew System::Windows::Forms::Label());
			this->lblInfo4 = (gcnew System::Windows::Forms::Label());
			this->lblInfo2 = (gcnew System::Windows::Forms::Label());
			this->txtTideStop = (gcnew System::Windows::Forms::TextBox());
			this->txtTriggerSpread = (gcnew System::Windows::Forms::TextBox());
			this->label8 = (gcnew System::Windows::Forms::Label());
			this->txtRoundPrice = (gcnew System::Windows::Forms::TextBox());
			this->label9 = (gcnew System::Windows::Forms::Label());
			this->label15 = (gcnew System::Windows::Forms::Label());
			this->toolTip1 = (gcnew System::Windows::Forms::ToolTip(this->components));
			this->label1 = (gcnew System::Windows::Forms::Label());
			this->txtTideStopSpace = (gcnew System::Windows::Forms::TextBox());
			this->lblInfo3 = (gcnew System::Windows::Forms::Label());
			this->label2 = (gcnew System::Windows::Forms::Label());
			this->txtRoundStopPrice = (gcnew System::Windows::Forms::TextBox());
			this->lblInfo7 = (gcnew System::Windows::Forms::Label());
			this->lblInfo1 = (gcnew System::Windows::Forms::Label());
			this->label3 = (gcnew System::Windows::Forms::Label());
			this->txtStopLossSpread = (gcnew System::Windows::Forms::TextBox());
			this->lblInfo5 = (gcnew System::Windows::Forms::Label());
			this->label4 = (gcnew System::Windows::Forms::Label());
			this->txtTideStopStartAfter = (gcnew System::Windows::Forms::TextBox());
			this->lblInfo8 = (gcnew System::Windows::Forms::Label());
			this->SuspendLayout();
			// 
			// cbLimit4Pro
			// 
			this->cbLimit4Pro->BackColor = System::Drawing::Color::White;
			this->cbLimit4Pro->DropDownStyle = System::Windows::Forms::ComboBoxStyle::DropDownList;
			this->cbLimit4Pro->Enabled = false;
			this->cbLimit4Pro->FormattingEnabled = true;
			this->cbLimit4Pro->Location = System::Drawing::Point(127, 97);
			this->cbLimit4Pro->Name = L"cbLimit4Pro";
			this->cbLimit4Pro->Size = System::Drawing::Size(106, 21);
			this->cbLimit4Pro->TabIndex = 13;
			this->cbLimit4Pro->TabStop = false;
			// 
			// cbLimit3Pro
			// 
			this->cbLimit3Pro->BackColor = System::Drawing::Color::White;
			this->cbLimit3Pro->DropDownStyle = System::Windows::Forms::ComboBoxStyle::DropDownList;
			this->cbLimit3Pro->Enabled = false;
			this->cbLimit3Pro->FormattingEnabled = true;
			this->cbLimit3Pro->Location = System::Drawing::Point(127, 76);
			this->cbLimit3Pro->Name = L"cbLimit3Pro";
			this->cbLimit3Pro->Size = System::Drawing::Size(106, 21);
			this->cbLimit3Pro->TabIndex = 13;
			this->cbLimit3Pro->TabStop = false;
			this->cbLimit3Pro->SelectedIndexChanged += gcnew System::EventHandler(this, &frmStrategy1::cbLimit3Pro_SelectedIndexChanged);
			// 
			// cbLimit2Pro
			// 
			this->cbLimit2Pro->BackColor = System::Drawing::Color::White;
			this->cbLimit2Pro->DropDownStyle = System::Windows::Forms::ComboBoxStyle::DropDownList;
			this->cbLimit2Pro->Enabled = false;
			this->cbLimit2Pro->FormattingEnabled = true;
			this->cbLimit2Pro->Location = System::Drawing::Point(127, 53);
			this->cbLimit2Pro->Name = L"cbLimit2Pro";
			this->cbLimit2Pro->Size = System::Drawing::Size(106, 21);
			this->cbLimit2Pro->TabIndex = 13;
			this->cbLimit2Pro->TabStop = false;
			this->cbLimit2Pro->SelectedIndexChanged += gcnew System::EventHandler(this, &frmStrategy1::cbLimit2Pro_SelectedIndexChanged);
			// 
			// cbLimit1Pro
			// 
			this->cbLimit1Pro->BackColor = System::Drawing::Color::White;
			this->cbLimit1Pro->DropDownStyle = System::Windows::Forms::ComboBoxStyle::DropDownList;
			this->cbLimit1Pro->FormattingEnabled = true;
			this->cbLimit1Pro->Items->AddRange(gcnew cli::array< System::Object^  >(4) {L"All", L"Half", L"Third", L"Quarter"});
			this->cbLimit1Pro->Location = System::Drawing::Point(127, 32);
			this->cbLimit1Pro->Name = L"cbLimit1Pro";
			this->cbLimit1Pro->Size = System::Drawing::Size(106, 21);
			this->cbLimit1Pro->TabIndex = 13;
			this->cbLimit1Pro->TabStop = false;
			this->cbLimit1Pro->SelectedIndexChanged += gcnew System::EventHandler(this, &frmStrategy1::cbLimit1Pro_SelectedIndexChanged);
			// 
			// label12
			// 
			this->label12->AutoSize = true;
			this->label12->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label12->Location = System::Drawing::Point(17, 77);
			this->label12->Name = L"label12";
			this->label12->Size = System::Drawing::Size(48, 16);
			this->label12->TabIndex = 9;
			this->label12->Text = L"Limit 3:";
			// 
			// btnApplyL
			// 
			this->btnApplyL->BackColor = System::Drawing::SystemColors::Control;
			this->btnApplyL->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->btnApplyL->Location = System::Drawing::Point(99, 295);
			this->btnApplyL->Name = L"btnApplyL";
			this->btnApplyL->Size = System::Drawing::Size(76, 24);
			this->btnApplyL->TabIndex = 8;
			this->btnApplyL->TabStop = false;
			this->btnApplyL->Text = L"OK";
			this->btnApplyL->UseVisualStyleBackColor = false;
			this->btnApplyL->Click += gcnew System::EventHandler(this, &frmStrategy1::btnApplyL_Click);
			// 
			// label14
			// 
			this->label14->AutoSize = true;
			this->label14->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label14->Location = System::Drawing::Point(17, 98);
			this->label14->Name = L"label14";
			this->label14->Size = System::Drawing::Size(48, 16);
			this->label14->TabIndex = 9;
			this->label14->Text = L"Limit 4:";
			// 
			// label13
			// 
			this->label13->AutoSize = true;
			this->label13->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label13->Location = System::Drawing::Point(66, 9);
			this->label13->Name = L"label13";
			this->label13->Size = System::Drawing::Size(44, 16);
			this->label13->TabIndex = 9;
			this->label13->Text = L"Dest:";
			// 
			// label11
			// 
			this->label11->AutoSize = true;
			this->label11->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label11->Location = System::Drawing::Point(132, 9);
			this->label11->Name = L"label11";
			this->label11->Size = System::Drawing::Size(84, 16);
			this->label11->TabIndex = 9;
			this->label11->Text = L"Proportion:";
			// 
			// label6
			// 
			this->label6->AutoSize = true;
			this->label6->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label6->Location = System::Drawing::Point(17, 33);
			this->label6->Name = L"label6";
			this->label6->Size = System::Drawing::Size(48, 16);
			this->label6->TabIndex = 9;
			this->label6->Text = L"Limit 1:";
			// 
			// txtLimit3Dst
			// 
			this->txtLimit3Dst->Enabled = false;
			this->txtLimit3Dst->Location = System::Drawing::Point(71, 76);
			this->txtLimit3Dst->Name = L"txtLimit3Dst";
			this->txtLimit3Dst->Size = System::Drawing::Size(39, 20);
			this->txtLimit3Dst->TabIndex = 10;
			this->txtLimit3Dst->TabStop = false;
			// 
			// label7
			// 
			this->label7->AutoSize = true;
			this->label7->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label7->Location = System::Drawing::Point(17, 54);
			this->label7->Name = L"label7";
			this->label7->Size = System::Drawing::Size(48, 16);
			this->label7->TabIndex = 9;
			this->label7->Text = L"Limit 2:";
			// 
			// txtLimit4Dst
			// 
			this->txtLimit4Dst->Enabled = false;
			this->txtLimit4Dst->Location = System::Drawing::Point(71, 97);
			this->txtLimit4Dst->Name = L"txtLimit4Dst";
			this->txtLimit4Dst->Size = System::Drawing::Size(39, 20);
			this->txtLimit4Dst->TabIndex = 10;
			this->txtLimit4Dst->TabStop = false;
			// 
			// txtLimit1Dst
			// 
			this->txtLimit1Dst->Location = System::Drawing::Point(71, 32);
			this->txtLimit1Dst->Name = L"txtLimit1Dst";
			this->txtLimit1Dst->Size = System::Drawing::Size(39, 20);
			this->txtLimit1Dst->TabIndex = 10;
			this->txtLimit1Dst->TabStop = false;
			// 
			// txtLimit2Dst
			// 
			this->txtLimit2Dst->Enabled = false;
			this->txtLimit2Dst->Location = System::Drawing::Point(71, 53);
			this->txtLimit2Dst->Name = L"txtLimit2Dst";
			this->txtLimit2Dst->Size = System::Drawing::Size(39, 20);
			this->txtLimit2Dst->TabIndex = 10;
			this->txtLimit2Dst->TabStop = false;
			// 
			// lblInfo6
			// 
			this->lblInfo6->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo6->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo6->Location = System::Drawing::Point(245, 241);
			this->lblInfo6->Name = L"lblInfo6";
			this->lblInfo6->Size = System::Drawing::Size(18, 19);
			this->lblInfo6->TabIndex = 20;
			this->lblInfo6->Text = L"\?";
			// 
			// lblInfo4
			// 
			this->lblInfo4->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo4->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo4->Location = System::Drawing::Point(245, 197);
			this->lblInfo4->Name = L"lblInfo4";
			this->lblInfo4->Size = System::Drawing::Size(18, 19);
			this->lblInfo4->TabIndex = 21;
			this->lblInfo4->Text = L"\?";
			// 
			// lblInfo2
			// 
			this->lblInfo2->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo2->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo2->Location = System::Drawing::Point(245, 129);
			this->lblInfo2->Name = L"lblInfo2";
			this->lblInfo2->Size = System::Drawing::Size(18, 19);
			this->lblInfo2->TabIndex = 22;
			this->lblInfo2->Text = L"\?";
			// 
			// txtTideStop
			// 
			this->txtTideStop->Location = System::Drawing::Point(144, 129);
			this->txtTideStop->Name = L"txtTideStop";
			this->txtTideStop->Size = System::Drawing::Size(95, 20);
			this->txtTideStop->TabIndex = 17;
			this->txtTideStop->TabStop = false;
			// 
			// txtTriggerSpread
			// 
			this->txtTriggerSpread->Location = System::Drawing::Point(211, 196);
			this->txtTriggerSpread->Name = L"txtTriggerSpread";
			this->txtTriggerSpread->Size = System::Drawing::Size(29, 20);
			this->txtTriggerSpread->TabIndex = 18;
			this->txtTriggerSpread->TabStop = false;
			// 
			// label8
			// 
			this->label8->AutoSize = true;
			this->label8->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label8->Location = System::Drawing::Point(6, 130);
			this->label8->Name = L"label8";
			this->label8->Size = System::Drawing::Size(132, 16);
			this->label8->TabIndex = 14;
			this->label8->Text = L"Trailing Stop Thresh:";
			// 
			// txtRoundPrice
			// 
			this->txtRoundPrice->Location = System::Drawing::Point(102, 243);
			this->txtRoundPrice->Name = L"txtRoundPrice";
			this->txtRoundPrice->Size = System::Drawing::Size(108, 20);
			this->txtRoundPrice->TabIndex = 19;
			// 
			// label9
			// 
			this->label9->AutoSize = true;
			this->label9->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label9->Location = System::Drawing::Point(6, 197);
			this->label9->Name = L"label9";
			this->label9->Size = System::Drawing::Size(204, 16);
			this->label9->TabIndex = 15;
			this->label9->Text = L"Trigger Spread 10% From Stop +";
			// 
			// label15
			// 
			this->label15->AutoSize = true;
			this->label15->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label15->Location = System::Drawing::Point(6, 244);
			this->label15->Name = L"label15";
			this->label15->Size = System::Drawing::Size(237, 16);
			this->label15->TabIndex = 16;
			this->label15->Text = L"Round a price                                        % R";
			// 
			// toolTip1
			// 
			this->toolTip1->AutomaticDelay = 0;
			this->toolTip1->IsBalloon = true;
			this->toolTip1->ShowAlways = true;
			this->toolTip1->ToolTipIcon = System::Windows::Forms::ToolTipIcon::Info;
			// 
			// label1
			// 
			this->label1->AutoSize = true;
			this->label1->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label1->Location = System::Drawing::Point(6, 152);
			this->label1->Name = L"label1";
			this->label1->Size = System::Drawing::Size(239, 16);
			this->label1->TabIndex = 15;
			this->label1->Text = L"Trailing Stop Thresh Space:              %R";
			// 
			// txtTideStopSpace
			// 
			this->txtTideStopSpace->Location = System::Drawing::Point(182, 152);
			this->txtTideStopSpace->Name = L"txtTideStopSpace";
			this->txtTideStopSpace->Size = System::Drawing::Size(33, 20);
			this->txtTideStopSpace->TabIndex = 18;
			this->txtTideStopSpace->TabStop = false;
			// 
			// lblInfo3
			// 
			this->lblInfo3->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo3->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo3->Location = System::Drawing::Point(245, 151);
			this->lblInfo3->Name = L"lblInfo3";
			this->lblInfo3->Size = System::Drawing::Size(18, 19);
			this->lblInfo3->TabIndex = 21;
			this->lblInfo3->Text = L"\?";
			// 
			// label2
			// 
			this->label2->AutoSize = true;
			this->label2->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label2->Location = System::Drawing::Point(6, 267);
			this->label2->Name = L"label2";
			this->label2->Size = System::Drawing::Size(240, 16);
			this->label2->TabIndex = 16;
			this->label2->Text = L"Round a stop loss price                      % R";
			// 
			// txtRoundStopPrice
			// 
			this->txtRoundStopPrice->Location = System::Drawing::Point(154, 266);
			this->txtRoundStopPrice->Name = L"txtRoundStopPrice";
			this->txtRoundStopPrice->Size = System::Drawing::Size(56, 20);
			this->txtRoundStopPrice->TabIndex = 19;
			// 
			// lblInfo7
			// 
			this->lblInfo7->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo7->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo7->Location = System::Drawing::Point(245, 264);
			this->lblInfo7->Name = L"lblInfo7";
			this->lblInfo7->Size = System::Drawing::Size(18, 19);
			this->lblInfo7->TabIndex = 20;
			this->lblInfo7->Text = L"\?";
			// 
			// lblInfo1
			// 
			this->lblInfo1->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo1->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo1->Location = System::Drawing::Point(245, 9);
			this->lblInfo1->Name = L"lblInfo1";
			this->lblInfo1->Size = System::Drawing::Size(18, 19);
			this->lblInfo1->TabIndex = 22;
			this->lblInfo1->Text = L"\?";
			// 
			// label3
			// 
			this->label3->AutoSize = true;
			this->label3->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label3->Location = System::Drawing::Point(6, 222);
			this->label3->Name = L"label3";
			this->label3->Size = System::Drawing::Size(237, 16);
			this->label3->TabIndex = 15;
			this->label3->Text = L"StopLoss Spread                                 % R";
			// 
			// txtStopLossSpread
			// 
			this->txtStopLossSpread->Location = System::Drawing::Point(122, 221);
			this->txtStopLossSpread->Name = L"txtStopLossSpread";
			this->txtStopLossSpread->Size = System::Drawing::Size(88, 20);
			this->txtStopLossSpread->TabIndex = 18;
			this->txtStopLossSpread->TabStop = false;
			// 
			// lblInfo5
			// 
			this->lblInfo5->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo5->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo5->Location = System::Drawing::Point(245, 219);
			this->lblInfo5->Name = L"lblInfo5";
			this->lblInfo5->Size = System::Drawing::Size(18, 19);
			this->lblInfo5->TabIndex = 21;
			this->lblInfo5->Text = L"\?";
			// 
			// label4
			// 
			this->label4->AutoSize = true;
			this->label4->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Regular, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->label4->Location = System::Drawing::Point(6, 175);
			this->label4->Name = L"label4";
			this->label4->Size = System::Drawing::Size(238, 16);
			this->label4->TabIndex = 15;
			this->label4->Text = L"Trailing Stop Period                   (minutes)";
			// 
			// txtTideStopStartAfter
			// 
			this->txtTideStopStartAfter->Location = System::Drawing::Point(135, 173);
			this->txtTideStopStartAfter->Name = L"txtTideStopStartAfter";
			this->txtTideStopStartAfter->Size = System::Drawing::Size(40, 20);
			this->txtTideStopStartAfter->TabIndex = 18;
			this->txtTideStopStartAfter->TabStop = false;
			// 
			// lblInfo8
			// 
			this->lblInfo8->BorderStyle = System::Windows::Forms::BorderStyle::FixedSingle;
			this->lblInfo8->Font = (gcnew System::Drawing::Font(L"Microsoft Sans Serif", 9.75F, System::Drawing::FontStyle::Bold, System::Drawing::GraphicsUnit::Point, 
				static_cast<System::Byte>(177)));
			this->lblInfo8->Location = System::Drawing::Point(245, 173);
			this->lblInfo8->Name = L"lblInfo8";
			this->lblInfo8->Size = System::Drawing::Size(18, 19);
			this->lblInfo8->TabIndex = 21;
			this->lblInfo8->Text = L"\?";
			// 
			// frmStrategy1
			// 
			this->AutoScaleDimensions = System::Drawing::SizeF(6, 13);
			this->AutoScaleMode = System::Windows::Forms::AutoScaleMode::Font;
			this->ClientSize = System::Drawing::Size(277, 326);
			this->Controls->Add(this->lblInfo7);
			this->Controls->Add(this->lblInfo6);
			this->Controls->Add(this->lblInfo8);
			this->Controls->Add(this->lblInfo3);
			this->Controls->Add(this->lblInfo5);
			this->Controls->Add(this->lblInfo4);
			this->Controls->Add(this->lblInfo1);
			this->Controls->Add(this->lblInfo2);
			this->Controls->Add(this->txtTideStop);
			this->Controls->Add(this->txtTideStopStartAfter);
			this->Controls->Add(this->txtTideStopSpace);
			this->Controls->Add(this->txtStopLossSpread);
			this->Controls->Add(this->txtTriggerSpread);
			this->Controls->Add(this->label8);
			this->Controls->Add(this->txtRoundStopPrice);
			this->Controls->Add(this->txtRoundPrice);
			this->Controls->Add(this->label4);
			this->Controls->Add(this->label1);
			this->Controls->Add(this->label3);
			this->Controls->Add(this->label9);
			this->Controls->Add(this->label2);
			this->Controls->Add(this->label15);
			this->Controls->Add(this->cbLimit4Pro);
			this->Controls->Add(this->cbLimit3Pro);
			this->Controls->Add(this->label13);
			this->Controls->Add(this->cbLimit2Pro);
			this->Controls->Add(this->txtLimit2Dst);
			this->Controls->Add(this->cbLimit1Pro);
			this->Controls->Add(this->txtLimit1Dst);
			this->Controls->Add(this->label12);
			this->Controls->Add(this->txtLimit4Dst);
			this->Controls->Add(this->btnApplyL);
			this->Controls->Add(this->label7);
			this->Controls->Add(this->label14);
			this->Controls->Add(this->txtLimit3Dst);
			this->Controls->Add(this->label6);
			this->Controls->Add(this->label11);
			this->FormBorderStyle = System::Windows::Forms::FormBorderStyle::FixedToolWindow;
			this->Name = L"frmStrategy1";
			this->StartPosition = System::Windows::Forms::FormStartPosition::CenterScreen;
			this->Text = L"Strategy 1 Options";
			this->Load += gcnew System::EventHandler(this, &frmStrategy1::frmStrategy1_Load);
			this->ResumeLayout(false);
			this->PerformLayout();

		}
#pragma endregion

	Account ^accPointer;

	private: System::Void frmStrategy1_Load(System::Object^  sender, System::EventArgs^  e)
			 {
				 cbLimit1Pro->Text = accPointer->PropToString(accPointer->LimitOptions->optLimit_1_Prop);
				 if (cbLimit1Pro->Text != "") txtLimit1Dst->Text = Convert::ToString(accPointer->LimitOptions->optLimit_1_Dest);
				 cbLimit1Pro_SelectedIndexChanged(sender, e);
				 cbLimit2Pro->Text = accPointer->PropToString(accPointer->LimitOptions->optLimit_2_Prop);
				 if (cbLimit2Pro->Text != "") txtLimit2Dst->Text = Convert::ToString(accPointer->LimitOptions->optLimit_2_Dest);
				 cbLimit2Pro_SelectedIndexChanged(sender, e);
				 cbLimit3Pro->Text = accPointer->PropToString(accPointer->LimitOptions->optLimit_3_Prop);
				 if (cbLimit3Pro->Text != "") txtLimit3Dst->Text = Convert::ToString(accPointer->LimitOptions->optLimit_3_Dest);
				 cbLimit3Pro_SelectedIndexChanged(sender, e);
				 cbLimit4Pro->Text = accPointer->PropToString(accPointer->LimitOptions->optLimit_4_Prop);
				 if (cbLimit4Pro->Text != "") txtLimit4Dst->Text = Convert::ToString(accPointer->LimitOptions->optLimit_4_Dest);

				 txtTideStop->Text = Convert::ToString(accPointer->TideStop);
				 txtTideStopSpace->Text = Convert::ToString(accPointer->LimitOptions->optTideStopSpace);
				 txtTideStopStartAfter->Text = Convert::ToString(accPointer->TideStopStartAfter);
				 if (txtTideStopSpace->Text == "0") txtTideStopSpace->Text = "0.00";
				 txtTriggerSpread->Text = Convert::ToString(accPointer->TriggerSpread);
				 if (txtTriggerSpread->Text == "0") txtTriggerSpread->Text = "0.00";
				 txtStopLossSpread->Text = Convert::ToString(accPointer->StopLossSpread);
				 txtRoundPrice->Text = Convert::ToString(accPointer->RoundANumber);
				 txtRoundStopPrice->Text = Convert::ToString(accPointer->RoundStopNumber);

				 toolTip1->SetToolTip(lblInfo1, "INFO 1");
				 toolTip1->SetToolTip(lblInfo2, "Counting the minutes to the end and divide them in the number you typed down, the number of minutes you get shows how minutes the software look back to move the stoploss to the lowest area in that time");
				 toolTip1->SetToolTip(lblInfo3, "How many cents do you want the stoploss to be below the lowest price (in long), in short it's the opposite");
			 	 toolTip1->SetToolTip(lblInfo8, "INFO 8");
				 toolTip1->SetToolTip(lblInfo4, "That the spread between the stop and the limit in the trigger. it's 10% from R + the number of cents you typed down");
				 toolTip1->SetToolTip(lblInfo5, "That the spread between the stop and the limit in the stoploss");
				 toolTip1->SetToolTip(lblInfo6, "How many percents from your risk do you want to loss for round and half-rounded price numbers");
				 toolTip1->SetToolTip(lblInfo7, "How many percents from your risk do you want to increase your risk for round and half-rounded price numbers");
				 toolTip1->Active;
			 }

	private: System::Void btnApplyL_Click(System::Object^  sender, System::EventArgs^  e)
			 {
				 if ( !Information::IsNumeric(txtLimit1Dst->Text) ) { MessageBox::Show("Please fill limit 1 correctly!"); return; }
				 if ( txtLimit2Dst->Enabled == true && (!Information::IsNumeric(txtLimit2Dst->Text) || cbLimit2Pro->Text == "") ) { MessageBox::Show("Please fill limit 2 correctly!"); return; }
				 if ( txtLimit3Dst->Enabled == true && (!Information::IsNumeric(txtLimit3Dst->Text) || cbLimit3Pro->Text == "") ) { MessageBox::Show("Please fill limit 3 correctly!"); return; }
				 if ( txtLimit4Dst->Enabled == true && (!Information::IsNumeric(txtLimit4Dst->Text) || cbLimit4Pro->Text == "") ) { MessageBox::Show("Please fill limit 4 correctly!"); return; }

				 AccountStrategy1Options ^strg_opt = gcnew AccountStrategy1Options;

				 this->Height = 131;
				 this->Width = 296;

				 strg_opt->optLimit_1_Dest = Convert::ToDouble(txtLimit1Dst->Text);
				 strg_opt->optLimit_1_Prop = accPointer->ConvertToProp(cbLimit1Pro->Text);

				 if (txtLimit2Dst->Enabled == true) { strg_opt->optLimit_2_Dest = Convert::ToDouble(txtLimit2Dst->Text); strg_opt->optLimit_2_Prop = accPointer->ConvertToProp(cbLimit2Pro->Text); }
				 else { strg_opt->optLimit_2_Dest = 0; strg_opt->optLimit_2_Prop = Propo::pNothing; }

				 if (txtLimit3Dst->Enabled == true) { strg_opt->optLimit_3_Dest = Convert::ToDouble(txtLimit3Dst->Text); strg_opt->optLimit_3_Prop = accPointer->ConvertToProp(cbLimit3Pro->Text); }
				 else { strg_opt->optLimit_3_Dest = 0; strg_opt->optLimit_3_Prop = Propo::pNothing; }

				 if (txtLimit4Dst->Enabled == true) {  strg_opt->optLimit_4_Dest = Convert::ToDouble(txtLimit4Dst->Text); strg_opt->optLimit_4_Prop = accPointer->ConvertToProp(cbLimit4Pro->Text); }
				 else { strg_opt->optLimit_4_Dest = 0; strg_opt->optLimit_4_Prop = Propo::pNothing; }

				 strg_opt->optTideStop = Convert::ToDouble(txtTideStop->Text);
				 strg_opt->optTideStopSpace = Convert::ToInt16(txtTideStopSpace->Text);
				 strg_opt->optTideStopStartAfter = Convert::ToDouble(txtTideStopStartAfter->Text);
				 strg_opt->optTriggerSpread = Convert::ToDouble(txtTriggerSpread->Text);
				 strg_opt->optStopLossSpread = Convert::ToInt16(txtStopLossSpread->Text);
				 strg_opt->optRoundANumber = Convert::ToInt16(txtRoundPrice->Text);
				 strg_opt->optRoundStopNumber = Convert::ToInt16(txtRoundStopPrice->Text);
				 accPointer->ChangeStrategy1Parameters(strg_opt);
				 Close();
			 }

	private: System::Void cbLimit1Pro_SelectedIndexChanged(System::Object^  sender, System::EventArgs^  e)
			 {
				 if (cbLimit1Pro->Text == "All")
				 {
					 txtLimit2Dst->Text = ""; txtLimit2Dst->Enabled = false; cbLimit2Pro->Enabled = false; cbLimit2Pro->Items->Clear();
					 txtLimit3Dst->Text = ""; txtLimit3Dst->Enabled = false; cbLimit3Pro->Enabled = false; cbLimit3Pro->Items->Clear();
					 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
				 }

				 if (cbLimit1Pro->Text == "Half")
				 {
					 txtLimit2Dst->Enabled = true; cbLimit2Pro->Enabled = true; cbLimit2Pro->Items->Clear(); cbLimit2Pro->Items->Add("Half"); cbLimit2Pro->Items->Add("Quarter");
					 txtLimit3Dst->Text = ""; txtLimit3Dst->Enabled = false; cbLimit3Pro->Enabled = false; cbLimit3Pro->Items->Clear();
					 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
				 }

				 if (cbLimit1Pro->Text == "Third")
				 {
					 txtLimit2Dst->Enabled = true; cbLimit2Pro->Enabled = true; cbLimit2Pro->Items->Clear(); cbLimit2Pro->Items->Add("Third"); cbLimit2Pro->Text = "Third";
					 txtLimit3Dst->Enabled = true; cbLimit3Pro->Enabled = true; cbLimit3Pro->Items->Clear(); cbLimit3Pro->Items->Add("Third"); cbLimit3Pro->Text = "Third";
					 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
				 }

				 if (cbLimit1Pro->Text == "Quarter")
				 {
					 txtLimit2Dst->Enabled = true; cbLimit2Pro->Enabled = true; cbLimit2Pro->Items->Clear(); cbLimit2Pro->Items->Add("Half"); cbLimit2Pro->Items->Add("Quarter");
					 txtLimit3Dst->Text = ""; txtLimit3Dst->Enabled = false; cbLimit3Pro->Enabled = false; cbLimit3Pro->Items->Clear();
					 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
				 }
			 }
	private: System::Void cbLimit2Pro_SelectedIndexChanged(System::Object^  sender, System::EventArgs^  e)
			 {
				 if (cbLimit1Pro->Text == "Half")
				 {
					 if (cbLimit2Pro->Text == "Half")
					 {
						 txtLimit3Dst->Text = ""; txtLimit3Dst->Enabled = false; cbLimit3Pro->Enabled = false; cbLimit3Pro->Items->Clear();
						 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
					 }

					 if (cbLimit2Pro->Text == "Quarter")
					 {
						 txtLimit3Dst->Enabled = true; cbLimit3Pro->Enabled = true; cbLimit3Pro->Items->Clear(); cbLimit3Pro->Items->Add("Quarter"); cbLimit3Pro->Text = "Quarter";
						 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
					 }
				 }

				 if (cbLimit1Pro->Text == "Quarter")
				 {
					 if (cbLimit2Pro->Text == "Half")
					 {
						 txtLimit3Dst->Enabled = true; cbLimit3Pro->Enabled = true; cbLimit3Pro->Items->Clear(); cbLimit3Pro->Items->Add("Quarter"); cbLimit3Pro->Text = "Quarter";
						 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
					 }

					 if (cbLimit2Pro->Text == "Quarter")
					 {
						 txtLimit3Dst->Enabled = true; cbLimit3Pro->Enabled = true; cbLimit3Pro->Items->Clear(); cbLimit3Pro->Items->Add("Half"); cbLimit3Pro->Items->Add("Quarter");
						 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
					 }
				 }
			 }

	private: System::Void cbLimit3Pro_SelectedIndexChanged(System::Object^  sender, System::EventArgs^  e)
			 {
				 if (cbLimit1Pro->Text == "Quarter" && cbLimit2Pro->Text == "Quarter" && cbLimit3Pro->Text == "Quarter")
				 {
					 txtLimit4Dst->Enabled = true; cbLimit4Pro->Enabled = true; cbLimit4Pro->Items->Clear(); cbLimit4Pro->Items->Add("Quarter"); cbLimit4Pro->Text = "Quarter";
				 }
				 if (cbLimit1Pro->Text == "Quarter" && cbLimit2Pro->Text == "Quarter" && cbLimit3Pro->Text == "Half")
				 {
					 txtLimit4Dst->Text = ""; txtLimit4Dst->Enabled = false; cbLimit4Pro->Enabled = false; cbLimit4Pro->Items->Clear();
				 }
			 }

};
}
